<script type="text/javascript" src="./js/tiny_mce/tiny_mce_gzip.js"></script>

<script type="text/javascript">
createTinyMCEOptimalization();
createForumWysiwyg("obsah");
</script>

<?

if($action != ACTION_SAVE_UPDATE) {
	$a_id = $_GET['id_aktualizace'];
	if($a_id != "") {
	  $query = getAktualizace($a_id);
	  $fetch = MySQL_Fetch_Array($query);
	  $a_version = $fetch["VERZE"];
	  $a_content = $fetch["OBSAH"];
	} else {
	  $a_version = "";
	  $a_content = "";
	}
}

?>

<form action="<? echo redirect_str(PAGE_ADMIN_UPDATES).action(ACTION_SAVE_UPDATE); ?>" method="post">
	<input type="hidden" name="a_id" value="<? echo $a_id;?>">
  
  	<fieldset>
    	<legend><? echo ($a_id!=""?"Úprava aktualizace":"Nová aktualizace"); ?></legend>
    	<table class="centered grid" style="font-size: 10px;">
  			<tr><td>Verze</td><td><input class="text" type="text" name="a_version" maxlength="10" value="<? echo $a_version; ?>" /></td></tr>
  			<tr><td>Obsah</td><td><textarea id="obsah" class="text px420 h150" name='a_content'><? echo $a_content; ?></textarea></td></tr>
  			<tr><td>         </td><td><input class="button" onmouseover="this.className='button_hover'" 
       				onmouseout="this.className='button'" type="submit" value="ULOŽIT"></td></tr>
		</table>
	</fieldset>
</form>